package dao;

import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;


public class DBUtil {
	public static Connection getConnection() throws ClassNotFoundException, SQLException {
		String username="nulll";
		String passwd="1234567a";

		String url="jdbc:mysql://192.168.0.105:3306/dormitory?characterEncoding=utf8&useSSL=false";

		
		

		//url="jdbc:mysql://192.168.2.125:3306/yuexiang_music?characterEncoding=utf8&useSSL=true";

		Class.forName("com.mysql.jdbc.Driver");
		Connection conn = DriverManager.getConnection(url, username, passwd);
		return conn;
	}
}
